package ArrayList;

import java.util.Objects;

/**
 * @author
 * @create 2018-09-27 21:59
 **/
public class Person {
    int idCard;
    String name;

    public Person(int idCard, String name) {
        this.idCard = idCard;
        this.name = name;
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;
        Person person = (Person) o;
        return idCard == person.idCard &&
                Objects.equals(name, person.name);
    }

}
